#include<bits/stdc++.h>
#define int long long
#define N 1000005
#define INF 1e18
using namespace std;
int n,a[N],fnt,ans;
signed main(){
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    cin>>n,ans=n;
    for(int i=1;i<=n;i++) cin>>a[i];
    sort(a+1,a+n+1),fnt=1;
    for(int i=1;i<=n;i++){
        while(a[fnt]==a[i]&&fnt<=n) fnt++;
        if(fnt==n+1) break;
        ans--,fnt++;
    }
    cout<<ans;
    return 0;
}